.class Lcom/glympse/android/glympse/ViewSearch$MyGlympseView;
.super Lcom/glympse/android/glympse/Glympse$GlympseView;
.source "ViewSearch.java"


# annotations
.annotation system Ldalvik/annotation/EnclosingClass;
    value = Lcom/glympse/android/glympse/ViewSearch;
.end annotation

.annotation system Ldalvik/annotation/InnerClass;
    accessFlags = 0x0
    name = "MyGlympseView"
.end annotation


# instance fields
.field final synthetic this$0:Lcom/glympse/android/glympse/ViewSearch;


# direct methods
.method constructor <init>(Lcom/glympse/android/glympse/ViewSearch;)V
    .locals 0
    .parameter

    .prologue
    .line 71
    iput-object p1, p0, Lcom/glympse/android/glympse/ViewSearch$MyGlympseView;->this$0:Lcom/glympse/android/glympse/ViewSearch;

    invoke-direct {p0}, Lcom/glympse/android/glympse/Glympse$GlympseView;-><init>()V

    return-void
.end method


# virtual methods
.method public OnGainFocus(Lcom/glympse/android/glympse/Glympse$EViews;)V
    .locals 5
    .parameter "viewPrevious"

    .prologue
    .line 76
    iget-object v1, p0, Lcom/glympse/android/glympse/ViewSearch$MyGlympseView;->this$0:Lcom/glympse/android/glympse/ViewSearch;

    invoke-static {v1}, Lcom/glympse/android/glympse/ViewSearch;->access$0(Lcom/glympse/android/glympse/ViewSearch;)Landroid/widget/AutoCompleteTextView;

    move-result-object v1

    if-nez v1, :cond_0

    .line 78
    iget-object v1, p0, Lcom/glympse/android/glympse/ViewSearch$MyGlympseView;->this$0:Lcom/glympse/android/glympse/ViewSearch;

    invoke-virtual {v1}, Lcom/glympse/android/glympse/ViewSearch;->getContext()Landroid/content/Context;

    move-result-object v1

    invoke-static {v1}, Landroid/view/LayoutInflater;->from(Landroid/content/Context;)Landroid/view/LayoutInflater;

    move-result-object v1

    const v2, 0x7f03001d

    iget-object v3, p0, Lcom/glympse/android/glympse/ViewSearch$MyGlympseView;->this$0:Lcom/glympse/android/glympse/ViewSearch;

    const/4 v4, 0x1

    invoke-virtual {v1, v2, v3, v4}, Landroid/view/LayoutInflater;->inflate(ILandroid/view/ViewGroup;Z)Landroid/view/View;

    move-result-object v0

    .line 80
    .local v0, oView:Landroid/view/View;
    iget-object v2, p0, Lcom/glympse/android/glympse/ViewSearch$MyGlympseView;->this$0:Lcom/glympse/android/glympse/ViewSearch;

    const v1, 0x7f0c0069

    invoke-virtual {v0, v1}, Landroid/view/View;->findViewById(I)Landroid/view/View;

    move-result-object v1

    check-cast v1, Landroid/widget/AutoCompleteTextView;

    invoke-static {v2, v1}, Lcom/glympse/android/glympse/ViewSearch;->access$1(Lcom/glympse/android/glympse/ViewSearch;Landroid/widget/AutoCompleteTextView;)V

    .line 81
    iget-object v2, p0, Lcom/glympse/android/glympse/ViewSearch$MyGlympseView;->this$0:Lcom/glympse/android/glympse/ViewSearch;

    const v1, 0x7f0c006a

    invoke-virtual {v0, v1}, Landroid/view/View;->findViewById(I)Landroid/view/View;

    move-result-object v1

    check-cast v1, Landroid/widget/ImageButton;

    invoke-static {v2, v1}, Lcom/glympse/android/glympse/ViewSearch;->access$2(Lcom/glympse/android/glympse/ViewSearch;Landroid/widget/ImageButton;)V

    .line 82
    iget-object v2, p0, Lcom/glympse/android/glympse/ViewSearch$MyGlympseView;->this$0:Lcom/glympse/android/glympse/ViewSearch;

    const v1, 0x7f0c0026

    invoke-virtual {v0, v1}, Landroid/view/View;->findViewById(I)Landroid/view/View;

    move-result-object v1

    check-cast v1, Landroid/widget/ListView;

    invoke-static {v2, v1}, Lcom/glympse/android/glympse/ViewSearch;->access$3(Lcom/glympse/android/glympse/ViewSearch;Landroid/widget/ListView;)V

    .line 83
    iget-object v2, p0, Lcom/glympse/android/glympse/ViewSearch$MyGlympseView;->this$0:Lcom/glympse/android/glympse/ViewSearch;

    const v1, 0x7f0c006b

    invoke-virtual {v0, v1}, Landroid/view/View;->findViewById(I)Landroid/view/View;

    move-result-object v1

    check-cast v1, Landroid/widget/TextView;

    invoke-static {v2, v1}, Lcom/glympse/android/glympse/ViewSearch;->access$4(Lcom/glympse/android/glympse/ViewSearch;Landroid/widget/TextView;)V

    .line 85
    iget-object v1, p0, Lcom/glympse/android/glympse/ViewSearch$MyGlympseView;->this$0:Lcom/glympse/android/glympse/ViewSearch;

    new-instance v2, Lcom/glympse/android/glympse/ViewSearch$OnTextChangedListenerSearch;

    iget-object v3, p0, Lcom/glympse/android/glympse/ViewSearch$MyGlympseView;->this$0:Lcom/glympse/android/glympse/ViewSearch;

    invoke-direct {v2, v3}, Lcom/glympse/android/glympse/ViewSearch$OnTextChangedListenerSearch;-><init>(Lcom/glympse/android/glympse/ViewSearch;)V

    invoke-static {v1, v2}, Lcom/glympse/android/glympse/ViewSearch;->access$5(Lcom/glympse/android/glympse/ViewSearch;Lcom/glympse/android/glympse/ViewSearch$OnTextChangedListenerSearch;)V

    .line 86
    iget-object v1, p0, Lcom/glympse/android/glympse/ViewSearch$MyGlympseView;->this$0:Lcom/glympse/android/glympse/ViewSearch;

    invoke-static {v1}, Lcom/glympse/android/glympse/ViewSearch;->access$0(Lcom/glympse/android/glympse/ViewSearch;)Landroid/widget/AutoCompleteTextView;

    move-result-object v1

    iget-object v2, p0, Lcom/glympse/android/glympse/ViewSearch$MyGlympseView;->this$0:Lcom/glympse/android/glympse/ViewSearch;

    invoke-static {v2}, Lcom/glympse/android/glympse/ViewSearch;->access$6(Lcom/glympse/android/glympse/ViewSearch;)Lcom/glympse/android/glympse/ViewSearch$OnTextChangedListenerSearch;

    move-result-object v2

    invoke-virtual {v1, v2}, Landroid/widget/AutoCompleteTextView;->addTextChangedListener(Landroid/text/TextWatcher;)V

    .line 87
    iget-object v1, p0, Lcom/glympse/android/glympse/ViewSearch$MyGlympseView;->this$0:Lcom/glympse/android/glympse/ViewSearch;

    invoke-static {v1}, Lcom/glympse/android/glympse/ViewSearch;->access$0(Lcom/glympse/android/glympse/ViewSearch;)Landroid/widget/AutoCompleteTextView;

    move-result-object v1

    iget-object v2, p0, Lcom/glympse/android/glympse/ViewSearch$MyGlympseView;->this$0:Lcom/glympse/android/glympse/ViewSearch;

    invoke-static {v2}, Lcom/glympse/android/glympse/ViewSearch;->access$6(Lcom/glympse/android/glympse/ViewSearch;)Lcom/glympse/android/glympse/ViewSearch$OnTextChangedListenerSearch;

    move-result-object v2

    invoke-virtual {v1, v2}, Landroid/widget/AutoCompleteTextView;->setOnKeyListener(Landroid/view/View$OnKeyListener;)V

    .line 88
    iget-object v1, p0, Lcom/glympse/android/glympse/ViewSearch$MyGlympseView;->this$0:Lcom/glympse/android/glympse/ViewSearch;

    invoke-static {v1}, Lcom/glympse/android/glympse/ViewSearch;->access$0(Lcom/glympse/android/glympse/ViewSearch;)Landroid/widget/AutoCompleteTextView;

    move-result-object v1

    new-instance v2, Lcom/glympse/android/glympse/ViewSearch$OnItemClickSearch;

    iget-object v3, p0, Lcom/glympse/android/glympse/ViewSearch$MyGlympseView;->this$0:Lcom/glympse/android/glympse/ViewSearch;

    invoke-direct {v2, v3}, Lcom/glympse/android/glympse/ViewSearch$OnItemClickSearch;-><init>(Lcom/glympse/android/glympse/ViewSearch;)V

    invoke-virtual {v1, v2}, Landroid/widget/AutoCompleteTextView;->setOnItemClickListener(Landroid/widget/AdapterView$OnItemClickListener;)V

    .line 89
    iget-object v1, p0, Lcom/glympse/android/glympse/ViewSearch$MyGlympseView;->this$0:Lcom/glympse/android/glympse/ViewSearch;

    invoke-static {v1}, Lcom/glympse/android/glympse/ViewSearch;->access$0(Lcom/glympse/android/glympse/ViewSearch;)Landroid/widget/AutoCompleteTextView;

    move-result-object v1

    new-instance v2, Lcom/glympse/android/glympse/ViewSearch$SearchAutoCompleteAdapter;

    iget-object v3, p0, Lcom/glympse/android/glympse/ViewSearch$MyGlympseView;->this$0:Lcom/glympse/android/glympse/ViewSearch;

    invoke-virtual {v3}, Lcom/glympse/android/glympse/ViewSearch;->getContext()Landroid/content/Context;

    move-result-object v3

    invoke-direct {v2, v3}, Lcom/glympse/android/glympse/ViewSearch$SearchAutoCompleteAdapter;-><init>(Landroid/content/Context;)V

    invoke-virtual {v1, v2}, Landroid/widget/AutoCompleteTextView;->setAdapter(Landroid/widget/ListAdapter;)V

    .line 90
    iget-object v1, p0, Lcom/glympse/android/glympse/ViewSearch$MyGlympseView;->this$0:Lcom/glympse/android/glympse/ViewSearch;

    invoke-static {v1}, Lcom/glympse/android/glympse/ViewSearch;->access$0(Lcom/glympse/android/glympse/ViewSearch;)Landroid/widget/AutoCompleteTextView;

    move-result-object v1

    iget-object v2, p0, Lcom/glympse/android/glympse/ViewSearch$MyGlympseView;->this$0:Lcom/glympse/android/glympse/ViewSearch;

    iget-object v2, v2, Lcom/glympse/android/glympse/ViewSearch;->m_strInitialText:Ljava/lang/String;

    invoke-static {v2}, Lcom/glympse/platform/common/Helpers;->SafeStr(Ljava/lang/String;)Ljava/lang/String;

    move-result-object v2

    invoke-virtual {v1, v2}, Landroid/widget/AutoCompleteTextView;->setText(Ljava/lang/CharSequence;)V

    .line 93
    iget-object v1, p0, Lcom/glympse/android/glympse/ViewSearch$MyGlympseView;->this$0:Lcom/glympse/android/glympse/ViewSearch;

    const/4 v2, 0x0

    iput-object v2, v1, Lcom/glympse/android/glympse/ViewSearch;->m_strInitialText:Ljava/lang/String;

    .line 95
    iget-object v1, p0, Lcom/glympse/android/glympse/ViewSearch$MyGlympseView;->this$0:Lcom/glympse/android/glympse/ViewSearch;

    invoke-static {v1}, Lcom/glympse/android/glympse/ViewSearch;->access$7(Lcom/glympse/android/glympse/ViewSearch;)Landroid/widget/ImageButton;

    move-result-object v1

    new-instance v2, Lcom/glympse/android/glympse/ViewSearch$OnClickSearch;

    iget-object v3, p0, Lcom/glympse/android/glympse/ViewSearch$MyGlympseView;->this$0:Lcom/glympse/android/glympse/ViewSearch;

    invoke-direct {v2, v3}, Lcom/glympse/android/glympse/ViewSearch$OnClickSearch;-><init>(Lcom/glympse/android/glympse/ViewSearch;)V

    invoke-virtual {v1, v2}, Landroid/widget/ImageButton;->setOnClickListener(Landroid/view/View$OnClickListener;)V

    .line 98
    iget-object v1, p0, Lcom/glympse/android/glympse/ViewSearch$MyGlympseView;->this$0:Lcom/glympse/android/glympse/ViewSearch;

    invoke-static {v1}, Lcom/glympse/android/glympse/ViewSearch;->access$8(Lcom/glympse/android/glympse/ViewSearch;)Landroid/widget/ListView;

    move-result-object v1

    iget-object v2, p0, Lcom/glympse/android/glympse/ViewSearch$MyGlympseView;->this$0:Lcom/glympse/android/glympse/ViewSearch;

    invoke-static {v2}, Lcom/glympse/android/glympse/ViewSearch;->access$9(Lcom/glympse/android/glympse/ViewSearch;)Landroid/widget/TextView;

    move-result-object v2

    invoke-virtual {v1, v2}, Landroid/widget/ListView;->setEmptyView(Landroid/view/View;)V

    .line 99
    iget-object v1, p0, Lcom/glympse/android/glympse/ViewSearch$MyGlympseView;->this$0:Lcom/glympse/android/glympse/ViewSearch;

    invoke-virtual {v1}, Lcom/glympse/android/glympse/ViewSearch;->BuildFavorites()V

    .line 101
    iget-object v1, p0, Lcom/glympse/android/glympse/ViewSearch$MyGlympseView;->this$0:Lcom/glympse/android/glympse/ViewSearch;

    invoke-static {v1}, Lcom/glympse/android/glympse/ViewSearch;->access$10(Lcom/glympse/android/glympse/ViewSearch;)V

    .line 104
    iget-object v1, p0, Lcom/glympse/android/glympse/ViewSearch$MyGlympseView;->this$0:Lcom/glympse/android/glympse/ViewSearch;

    invoke-static {v1}, Lcom/glympse/android/glympse/ViewSearch;->access$0(Lcom/glympse/android/glympse/ViewSearch;)Landroid/widget/AutoCompleteTextView;

    move-result-object v1

    const/4 v2, 0x0

    invoke-static {v1, v2}, Lcom/glympse/android/glympse/Glympse;->SetFocusDelayed(Landroid/view/View;Z)V

    .line 106
    .end local v0           #oView:Landroid/view/View;
    :cond_0
    return-void
.end method

.method public OnLoseFocus(Lcom/glympse/android/glympse/Glympse$EViews;)Z
    .locals 3
    .parameter "eViewNext"

    .prologue
    const/4 v2, 0x0

    .line 111
    sget-object v0, Lcom/glympse/android/glympse/Glympse$EViews;->Destination:Lcom/glympse/android/glympse/Glympse$EViews;

    if-eq v0, p1, :cond_1

    .line 113
    iget-object v0, p0, Lcom/glympse/android/glympse/ViewSearch$MyGlympseView;->this$0:Lcom/glympse/android/glympse/ViewSearch;

    invoke-static {v0}, Lcom/glympse/android/glympse/ViewSearch;->access$6(Lcom/glympse/android/glympse/ViewSearch;)Lcom/glympse/android/glympse/ViewSearch$OnTextChangedListenerSearch;

    move-result-object v0

    if-eqz v0, :cond_0

    iget-object v0, p0, Lcom/glympse/android/glympse/ViewSearch$MyGlympseView;->this$0:Lcom/glympse/android/glympse/ViewSearch;

    invoke-static {v0}, Lcom/glympse/android/glympse/ViewSearch;->access$0(Lcom/glympse/android/glympse/ViewSearch;)Landroid/widget/AutoCompleteTextView;

    move-result-object v0

    if-eqz v0, :cond_0

    .line 115
    iget-object v0, p0, Lcom/glympse/android/glympse/ViewSearch$MyGlympseView;->this$0:Lcom/glympse/android/glympse/ViewSearch;

    invoke-static {v0}, Lcom/glympse/android/glympse/ViewSearch;->access$0(Lcom/glympse/android/glympse/ViewSearch;)Landroid/widget/AutoCompleteTextView;

    move-result-object v0

    iget-object v1, p0, Lcom/glympse/android/glympse/ViewSearch$MyGlympseView;->this$0:Lcom/glympse/android/glympse/ViewSearch;

    invoke-static {v1}, Lcom/glympse/android/glympse/ViewSearch;->access$6(Lcom/glympse/android/glympse/ViewSearch;)Lcom/glympse/android/glympse/ViewSearch$OnTextChangedListenerSearch;

    move-result-object v1

    invoke-virtual {v0, v1}, Landroid/widget/AutoCompleteTextView;->removeTextChangedListener(Landroid/text/TextWatcher;)V

    .line 118
    :cond_0
    iget-object v0, p0, Lcom/glympse/android/glympse/ViewSearch$MyGlympseView;->this$0:Lcom/glympse/android/glympse/ViewSearch;

    invoke-static {v0, v2}, Lcom/glympse/android/glympse/ViewSearch;->access$1(Lcom/glympse/android/glympse/ViewSearch;Landroid/widget/AutoCompleteTextView;)V

    .line 119
    iget-object v0, p0, Lcom/glympse/android/glympse/ViewSearch$MyGlympseView;->this$0:Lcom/glympse/android/glympse/ViewSearch;

    invoke-static {v0, v2}, Lcom/glympse/android/glympse/ViewSearch;->access$2(Lcom/glympse/android/glympse/ViewSearch;Landroid/widget/ImageButton;)V

    .line 120
    iget-object v0, p0, Lcom/glympse/android/glympse/ViewSearch$MyGlympseView;->this$0:Lcom/glympse/android/glympse/ViewSearch;

    invoke-static {v0, v2}, Lcom/glympse/android/glympse/ViewSearch;->access$3(Lcom/glympse/android/glympse/ViewSearch;Landroid/widget/ListView;)V

    .line 121
    iget-object v0, p0, Lcom/glympse/android/glympse/ViewSearch$MyGlympseView;->this$0:Lcom/glympse/android/glympse/ViewSearch;

    invoke-static {v0, v2}, Lcom/glympse/android/glympse/ViewSearch;->access$4(Lcom/glympse/android/glympse/ViewSearch;Landroid/widget/TextView;)V

    .line 123
    iget-object v0, p0, Lcom/glympse/android/glympse/ViewSearch$MyGlympseView;->this$0:Lcom/glympse/android/glympse/ViewSearch;

    invoke-static {v0, v2}, Lcom/glympse/android/glympse/ViewSearch;->access$5(Lcom/glympse/android/glympse/ViewSearch;Lcom/glympse/android/glympse/ViewSearch$OnTextChangedListenerSearch;)V

    .line 125
    iget-object v0, p0, Lcom/glympse/android/glympse/ViewSearch$MyGlympseView;->this$0:Lcom/glympse/android/glympse/ViewSearch;

    invoke-virtual {v0}, Lcom/glympse/android/glympse/ViewSearch;->removeAllViews()V

    .line 128
    :cond_1
    const/4 v0, 0x1

    return v0
.end method
